.commentContainer {
  .commentInput {
    margin-bottom: 12px;
    

    
    .inputWrapper {
      display: flex;
      gap: 12px;
      
      .inputAvatar {
        flex-shrink: 0;
        margin-top: 4px;
      }
      
      .inputContent {
        flex: 1;
        
        .textArea {
          border: 1px solid #d9d9d9;
          border-radius: 8px;
          transition: all 0.3s ease;
          
          &:focus {
            border-color: #1890ff;
            box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.1);
          }
        }
        
        .inputActions {
          display: flex;
          justify-content: flex-end;
          align-items: center;
          gap: 12px;
          margin-top: 8px;

          .disabledTip {
            font-size: 12px;
            color: #ff4d4f;
          }
          
          .submitBtn {
            border-radius: 16px;
            padding: 0 16px;
            height: 32px;
            font-size: 12px;
            
            &:hover {
              transform: translateY(-1px);
              box-shadow: 0 2px 8px rgba(24, 144, 255, 0.3);
            }
          }
        }
      }
    }
  }
  
  .divider {
    margin: 12px 0;
  }
  
  .commentList {
    .loading {
      text-align: center;
      padding: 20px;
      color: #999;
    }
    
    .empty {
      padding: 20px;
    }
  }
}

.replyBoxContainer {
  margin: 16px 0;
  padding-left: 44px; // 与评论内容对齐
}

.commentItem {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  animation: fade-in-up 0.4s ease-out;

  .avatar {
    flex-shrink: 0;
    margin-top: 4px;
  }
  
  // 根据层级设置缩进
  &.level-0 {
    margin-left: 0; // 评论不缩进
  }
  
  &.level-1 {
    margin-left: 40px; // 一级回复缩进一次
  }
  
  &.level-2,
  &.level-3,
  &.level-4,
  &.level-5 {
    margin-left: 80px; // 二级及以上回复缩进两次
  }
  
  // 评论包装器
    .commentWrapper {
      margin-bottom: 24px;
      
      &:last-child {
        margin-bottom: 0;
      }
    }


  
  .commentContent {
    flex: 1;
    
    .commentHeader {
      display: flex;
      align-items: center;
      justify-content: space-between;
      margin-bottom: 8px;
      
      .userInfo {
        display: flex;
        align-items: center;
        gap: 8px;
        
        .username {
          font-weight: 600;
          font-size: 14px;  /* 从16px改为14px */
          color: #262626;
        }
        
        .replyArrow {
          font-size: 12px;
          color: #1890ff;
          margin: 0 6px;
        }
        
        .replyToUser {
          font-size: 14px;
          color: #1890ff;
          font-weight: 500;
        }
      }
      
      .time {
        font-size: 14px;
        color: #8c8c8c;
        flex-shrink: 0;
      }
    }
    
    .commentText {
      font-size: 16px;
      line-height: 1.6;
      color: #262626;
      margin-bottom: 12px;
      white-space: pre-wrap;
      word-break: break-word;
    }
    
    .commentActions {
      display: flex;
      gap: 12px;
      

      .replyBtn {
        font-size: 14px;
        height: 28px;
        padding: 0 12px;
        color: #1890ff;
        transition: all 0.3s ease;
        
        &:hover {
          background: rgba(24, 144, 255, 0.1);
          color: #40a9ff;
        }
      }
      
      .deleteBtn {
        font-size: 14px;
        height: 28px;
        padding: 0 12px;
        color: #8c8c8c;
        transition: all 0.3s ease;
        
        &:hover {
          background: rgba(255, 77, 79, 0.06);
          color: #ff4d4f;
        }
      }
    }
  }
  

}

/* 动画效果 */
@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slide-in {
  from {
    opacity: 0;
    transform: translateX(-10px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}



/* 响应式设计 */
@media (max-width: 768px) {
  .commentContainer {
    .commentInput {
      .inputWrapper {
        gap: 8px;
        
        .inputAvatar {
          width: 28px;
          height: 28px;
        }
      }
    }
  }
  
  .commentItem {
    gap: 8px;
    
    .avatar {
      width: 28px;
      height: 28px;
    }
    
    .commentContent {
      .commentHeader {
        .username {
          font-size: 13px;
        }
        
        .time {
          font-size: 11px;
        }
      }
      
      .commentText {
        font-size: 13px;
      }
      
      .replies {
        padding-left: 12px;
      }
    }
  }
}

/* 加载状态 */
@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.submitBtn:disabled {
  animation: pulse 1s infinite;
}

/* 悬浮效果 */
.commentItem:hover {
  .commentActions {
    .deleteBtn {
      opacity: 1;
    }
  }
}

.commentActions {
  .deleteBtn {
    opacity: 0.7;
    transition: opacity 0.3s ease;
  }
}